import ajax from './index'

export function order_list(condition) {
  if (!condition) {
    condition = {
      pageNum: 1,
      pageSize: 20
    }
  }
  return ajax({
    url: "/backend/order/list",
    method: "post",
    data: condition
  });
}
export function order_detail(id) {
  return ajax({
    url: "/backend/order/detail" + "/" + id,
    method: "get"
  });
}
export function order_settle_list(condition) {
  if (!condition) {
    condition = {
      pageNum: 1,
      pageSize: 20
    }
  }
  return ajax({
    url: "/backend/order/settle_list",
    method: "get",
    params: condition
  });
}

export function logistics_query(condition) {
  return ajax({
    url: "/backend/product/logisticsQuery",
    method: "get",
    params: condition
  });
}
export function order_profit_list(condition) {
  if (!condition) {
    condition = {
      pageNum: 1,
      pageSize: 20
    }
  }
  return ajax({
    url: "/backend/order/order_profit_list",
    method: "get",
    params: condition
  });
}
export function order_feedbackNew(data) {
  return ajax({
    url: "/backend/order/orderRefundVerify",
    method: "post",
    data: data
  });
}
export function order_feedbackHasSend(data) {
  return ajax({
    url: "/backend/order/feedbackHasSend",
    method: "post",
    data: data
  });
}
export function order_feedbackCancel(data) {
  return ajax({
    url: "/backend/order/feedbackCancel",
    method: "post",
    data: data
  });
}
export function order_feedbackConfirm(data) {
  return ajax({
    url: "/backend/order/feedbackConfirm",
    method: "post",
    data: data
  });
}
export function order_settle(ids) {
  return ajax({
    url: "/backend/order/orderSettle",
    method: "post",
    data: {
      ids: ids
    }
  });
}

export function order_in(ids) {
  return ajax({
    url: "/backend/order/orderIn",
    method: "post",
    data: {
      ids: ids
    }
  });
}
// 会员订单列表


export function shopVipOrderlist(data) {
  return ajax({
    url: "/backend/order/shopVipOrderlist?" + data,
    method: "post",
    // data:data
  });
}
// 商城订单列表
export function shopMallOrderlist(data) {
  return ajax({
    url: "/backend/order/shopMallOrderlist?" + data,
    method: "post",
    // data:data
  });
}
//现金券订单列表
export function couponOrderlist(data) {
  return ajax({
    url: "/backend/order/couponOrderlist",
    method: "post",
    params: data
  });
}
// 优惠订单列表
export function discountOrderlist(data) {
  return ajax({
    url: "/backend/order/discountOrderlist?" + data,
    method: "post",
    // data:data
  });
}
// 优惠订单列表
export function orderDetail(id) {
  return ajax({
    url: `/backend/order/detail/${id}`,
    method: "GET",
    // data:data
  });
}
export function transactionDetail(id) {
  return ajax({
    url: `/backend/finance/shop/transactionDetail/${id}`,
    method: "post",
    // data:data
  });
}
// ih


